import { client } from '../../request/index.js'
Page({
  data: {
    url: null,
    flag: false,
  },

  async link(id) {
    const mapData = await client({
      url: '/article/link',
      data: {
        id: id,
      },
    })
    console.log('文章信息:', mapData)
    this.setData({
      url: mapData.data.data.aticleurl,
      flag: true,
    })
  },

  onLoad: function (options) {
    let id = options.swiperId
    this.link(id)
  },
})
